<template>
  <view id="glspModel">
    <view
      @tap="handleSkipPage(item)"
      v-for="(item, index) in useActiveStore.activeList.list"
      :key="item.path"
      class="item">
      <view class="title fs_20">{{ item.label }}</view>
      <image :src="`../../static/img/other/${item.path}.png`" />
    </view>
  </view>
</template>

<script lang="ts" setup>
import { useActivePageStore } from "@/stores/modules/activePage";
import { onShow } from "@dcloudio/uni-app";
const useActiveStore = useActivePageStore();
onShow(() => {});
const handleSkipPage = (item: any) => {
  console.log(useActiveStore.activePage, item.path);
  uni.navigateTo({
    url: `/pages/${useActiveStore.activePage}/${item.path}/${item.path}`,
  });
};
</script>

<style lang="scss" scoped>
#glspModel {
  width: 100%;
  height: 100%;
  padding: 0 20px;
  display: flex;
  align-content: space-between;
  flex-wrap: wrap;
  .item {
    width: 30%;
    height: 48%;
    margin: 0 10px;
    border-radius: 4px;
    background: rgb(255, 255, 255);
    overflow: hidden;
    position: relative;
    box-shadow: 0 2px 12px 0 rgba(0, 0, 0, 0.1);
    padding: 24px;
    image {
      width: 180px;
      height: 180px;
      position: absolute;
      bottom: -15%;
      right: -5%;
      color: rgb(8, 18, 30);
    }
  }
}
</style>
